<!DOCTYPE HTML><html lang="en">
<HEAD>

<meta name="copyright" content="Copyright (c) IBM Corporation and others 2000, 2005. This page is made available under license. For full details see the LEGAL in the documentation book that contains this page." >

<meta charset="utf-8">
<LINK REL="STYLESHEET" HREF="../book.css" TYPE="text/css">
<TITLE>Compare support</TITLE>

<link rel="stylesheet" type="text/css" HREF="../book.css">
</HEAD>
<BODY>
<H1>
Compare support</H1>


<p>
If your plug-in defines and manipulates its own resource types, you may have
special requirements for comparing resources.&nbsp; Resources are often compared
when working with local history or with files from a repository.&nbsp; The <b>compare</b>
plug-in supports merging of multiple content streams and the implementation of advanced compare views.
Services provided by this plug-in include:</p>


<ul>
  <li>Interfaces for merging multiple text streams into a single output stream</li>
  <li>Two and three-way compare and merge components for hierarchical structures
    inferred from text</li>
  <li>Differencing engines for hierarchical structures and character ranges in
    text</li>
</ul>
<p>These services are used in the platform to assist with user tasks such as
integrating patch files and comparing/merging the workspace with local history.</p>
<h2>Compare Viewers</h2>
<p>
All compare viewers are standard <a href="jface_viewers.htm"> JFace viewers</a> that expect an input object implementing the
<b><a href="../reference/api/org/eclipse/compare/structuremergeviewer/ICompareInput.html">ICompareInput</a></b>
interface.</p>
<p>
Compare viewers are said to be
<a href="compare_contentviewer.htm">content-oriented</a>  if they compare flat
inputs such as text or images and
<a href="compare_structureviewer.htm">structure-oriented</a>  if they compare
hierarchically structured input elements.</p>


</BODY>
</HTML>
